package com.chuangke.system.service;

import java.util.List;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.chuangke.system.entity.SysRelation;

public interface SysRelationService {

	void save(String subjectId, String relationType, String relationId);

	void save(SysRelation sysRelation);

	void saveBatch(List<SysRelation> list);

	void delete(String subjectId, String relationId);

	void deleteBySubjectId(String subjectId);
	
	void deleteBySubjectId(String subjectId, String relationType);
	
	void deleteBySubjectIds(List<String> subjectIds, String relationType);
	
	void deleteBySubjectIds(List<String> subjectIds);

	void deleteByRelationId(String relationId);

	List<String> findRelationIdsBySubjectId(String subjectId);
	
	List<String> findRelationIdsByRelationType(String subjectId,String relationType);
	
	List<String> findRelationIdsByRelationTypes(List<String> subjectIds,List<String> relationTypes);
	
	List<SysRelation> findBySubjectId(String subjectId);
	
	List<SysRelation> findBySubjectIds(List<String> subjectIds);
	
	List<SysRelation> findByByRelationTypes(List<String> subjectIds,List<String> relationTypes);
	
	List<SysRelation> list(QueryWrapper<SysRelation> qw) ;

}
